package com.financing.wap.dao.impl;


import java.sql.SQLException;
import java.util.List;
import java.util.Map;
import org.springframework.stereotype.Repository;
import com.financing.wap.dto.DstUserPayLogDTO;
import com.financing.wap.dao.IDstUserPayLogDao;
import com.financing.wap.common.SqlName;
/**
 * dst_user_pay_log  
 * 用户支付流水 数据访问层实现类
 * @author huqiyun
 *
 */
 
@Repository("dstUserPayLogDao")
public class DstUserPayLogDaoImpl extends BaseDaoImpl<DstUserPayLogDTO, java.lang.Integer> implements IDstUserPayLogDao {


	@Override
	public int insert(DstUserPayLogDTO dstUserPayLog) throws SQLException {
		return (Integer) this.sqlMapClientTemplate.insert(SqlName.DstUserPayLogSql.insert, dstUserPayLog);
	}

	@Override
	public void update(DstUserPayLogDTO dstUserPayLog) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.DstUserPayLogSql.update, dstUserPayLog);
	}

	@Override
	public void updateForce(DstUserPayLogDTO dstUserPayLog) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.DstUserPayLogSql.updateForce, dstUserPayLog);
	}

	@Override
	public void delete(Integer id) throws SQLException {
		this.sqlMapClientTemplate.delete(SqlName.DstUserPayLogSql.delete,id);
	}
	
	@SuppressWarnings("unchecked")	
	@Override
	public List<DstUserPayLogDTO> queryList(DstUserPayLogDTO dstUserPayLog) throws SQLException {
		return this.sqlMapClientTemplate.queryForList(SqlName.DstUserPayLogSql.queryList, dstUserPayLog);
	}

	@Override
	public int queryListCount(DstUserPayLogDTO dstUserPayLog) throws SQLException {
		return (Integer) this.sqlMapClientTemplate.queryForObject(SqlName.DstUserPayLogSql.queryListCount, dstUserPayLog);
	}

	@Override
	public DstUserPayLogDTO loadById(Integer id) throws SQLException {
		return  (DstUserPayLogDTO)this.getSqlMapClientTemplate().queryForObject(SqlName.DstUserPayLogSql.loadById,id);
	}

	@Override
	public Class<DstUserPayLogDTO> getEntityClass() {
		return DstUserPayLogDTO.class;
	}
 	
}
